package com.alxy.day1.repository;

import com.alxy.day1.entity.Account;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Optional;

/**
 * @author 爱莉希雅
 * @version java 17
 */
@SuppressWarnings({"all"})
@Repository
public interface AccountRepository extends JpaRepository<Account,Long> {
    //根据ID查询账户
    @Override
    Optional<Account> findById(Long aLong);
    //转账
    @Override
    <S extends Account> S saveAndFlush(S entity);
}
